package com.zky.utils;

import lombok.Builder;
import lombok.Data;

import java.io.Serializable;

@Builder
@Data
public   class  Result {
    private int code;
    private String msg;
    private Object data;
    public static Result success()
    {
        return Result.builder().data("").code(200).msg("").build();
    }
    public static Result success(Object data)
    {
        return Result.builder().data(data).code(200).msg("").build();
    }
    public static Result fail(String msg)
    {
        return Result.builder().data("").code(401).msg(msg).build();
    }

}
